class ChangeUsers < ActiveRecord::Migration
  def self.up
    add_column :users, :name, :string, :default =>"" ,:null => false
    add_column :users, :first_name, :string, :default =>"" ,:null => false
    add_column :users, :birth_date, :date, :default =>"2010-01-01 00:00:00" ,:null => false
    add_column :users, :hiring_date, :date, :default =>"2010-01-01 00:00:00" ,:null => false
    add_column :users, :departure_date, :date
    add_column :users, :adress, :string, :default =>"" ,:null => false
    add_column :users, :zip_code, :string, :default =>"" ,:null => false
    add_column :users, :city, :string, :default =>"" ,:null => false
    add_column :users, :mobile_phone, :string
    add_column :users, :office_phone, :string
  end

  def self.down
    remove_column :users, :name
    remove_column :users, :first_name
    remove_column :users, :birth_date
    remove_column :users, :hiring_date
    remove_column :users, :departure_date
    remove_column :users, :adress
    remove_column :users, :zip_code
    remove_column :users, :city
    remove_column :users, :mobile_phone
    remove_column :users, :office_phone
  end
end
